<?php


namespace api\controllers;


use common\helpers\WeChatApi;
use common\models\Order;
use common\models\System;
use yii\web\Controller;

/**
 * 回调
 */
class NotifyController extends Controller
{
    /**
     * 订单微信支付回调
     * @return void
     */
    public function actionWx()
    {
        $config = System::pay();
        $wx = new WeChatApi($config);
        $wx->payNotify(Order::className(),'notify');
    }
}